package com.yincheng.oes.business.util;

import java.util.ArrayList;
import java.util.List;
import org.apache.commons.collections4.CollectionUtils;

/**
 * @Author: yangsy
 * @Contact: 446948434@qq.com
 * @Date: 2021/9/17 22:03
 * @Version: 1.0
 * @Description:
 */
public class ArrayUtil {

    /**
     * 将导出到word中的特殊字符转义
     *
     * @param list 带转换的字符串集合
     * @return 转义后的字符串
     */
    public static List<String> transform(List<String> list) {
        if (CollectionUtils.isEmpty(list)) {
            return list;
        }

        List<String> nList = new ArrayList<>();
        for (String str : list) {
            nList.add(StringUtil.transform(str));
        }
        return nList;
    }
}
